﻿<Page x:Class="Stankovita.Program.Pages.SignInOut"
      xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
      xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
      xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" 
      xmlns:d="http://schemas.microsoft.com/expression/blend/2008" 
      xmlns:local="clr-namespace:Stankovita.Program.Pages"
      mc:Ignorable="d" 
      d:DesignHeight="650" d:DesignWidth="850"
      Title="SignInOut">

    <Grid Background="WhiteSmoke">

        <!--Назад в режим подключения-->
        <Button Name="BackBtn"
                Style="{DynamicResource ButtonStyle}"
                Content="Назад"
                VerticalAlignment="Top"
                FontSize="20"
                Margin="5" 
                Click="BackBtn_Click"/>

        <!--#region ФОРМА ДЛЯ АВТОРИЗАЦИИ ЗАКАЗЧИКА-->
        <Grid Name="gridFormAuthCustomer"
              VerticalAlignment="Center"
              Height="350"
              Width="450"
              Visibility="Hidden">

            <Grid.RowDefinitions>
                <RowDefinition/>
                <RowDefinition Height="50"/>
                <RowDefinition Height="50"/>
            </Grid.RowDefinitions>

            <GroupBox Header="Вход за заказчика"
                      Foreground="Black"
                      FontSize="20"
                      Padding="5"
                      BorderBrush="Black"
                      Margin="10"
                      BorderThickness="3">

                <Grid Margin="10">

                    <Grid.RowDefinitions>
                        <RowDefinition/>
                        <RowDefinition/>
                    </Grid.RowDefinitions>

                    <!--Элементы в GroupBox-->
                    <StackPanel>

                        <TextBlock Text="Логин"/>
                        <TextBox Name="CustomerLoginAuthTxb"
                                 Background="WhiteSmoke"
                                 Height="35"
                                 VerticalContentAlignment="Center"/>

                    </StackPanel>

                    <StackPanel Grid.Row="1">

                        <TextBlock Text="Пароль"/>
                        <PasswordBox Name="CustomerPassAuthPbx"
                                     Height="35"
                                     Background="WhiteSmoke"
                                     VerticalContentAlignment="Center"/>

                    </StackPanel>

                </Grid>

            </GroupBox>

            <Button Name="AuthCustomerBtn"
                    Style="{DynamicResource ButtonStyle}"
                    Grid.Row="1"
                    Content="Войти"
                    FontSize="20"
                    Width="100"
                    Click="AuthCustomerBtn_Click"/>

            <Button Name="OpenRegCustomerBtn"
                    Style="{DynamicResource ButtonStyle}"
                    Grid.Row="2"
                    Content="Зарегистрироваться"
                    FontSize="18"
                    Width="300"
                    Margin="3"
                    Click="OpenRegCustomerBtn_Click"/>
        </Grid>

        <!--Капча-->
        <Grid Name="GridCaptcha"
              Background="#FF4CB034"
              VerticalAlignment="Bottom"
              Height="40"
              Visibility="Hidden"
              Width="370"
              Margin="0 0 0 50">

            <Grid.ColumnDefinitions>
                <ColumnDefinition Width="290"/>
                <ColumnDefinition/>
            </Grid.ColumnDefinitions>

            <StackPanel Orientation="Horizontal">
                <TextBlock Name="CaptchaLb" 
                           FontFamily="Lucida Handwriting" 
                           FontStyle="Italic"
                           Text="MMDDDD"
                           TextAlignment="Center"
                           VerticalAlignment="Center"
                           TextDecorations="Strikethrough"
                           FontSize="20"
                           Foreground="DarkViolet"
                           Margin="5 0 5 0">
                    <TextBlock.Background>
                        <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                            <GradientStop Color="#FF9400D4"/>
                            <GradientStop Color="#FF9DCA93" Offset="1"/>
                        </LinearGradientBrush>
                    </TextBlock.Background>
                </TextBlock>
                <TextBox Name="InputCaptchaTxb"
                     Text="text"
                     FontSize="20"
                     VerticalAlignment="Center" Width="167"/>
            </StackPanel>
            <Button Name="CheckCaptchaBtn"
                    Grid.Column="2"
                    Content="Проверка"
                    FontSize="15"
                    Background="White"
                    Margin="0 5 5 5"
                    Click="CheckCaptchaBtn_Click">
                <Button.Resources>
                    <Style TargetType="Border">
                        <Setter Property="CornerRadius" Value="5"/>
                    </Style>
                </Button.Resources>
            </Button>
        </Grid>
        <!--#endregion ФОРМА ДЛЯ АВТОРИЗАЦИИ ЗАКАЗЧИКА -->

        <!--#region ФОРМА ДЛЯ РЕГИСТРАЦИИ ЗАКАЗЧИКА-->
        <Grid Name="GridFormRegCustomer"
              VerticalAlignment="Center"
              Height="450"
              Width="500"
              Visibility="Hidden">

            <Grid.RowDefinitions>
                <RowDefinition/>
                <RowDefinition Height="60"/>
            </Grid.RowDefinitions>

            <GroupBox Header="Регистрация заказчика"
                      Foreground="Black"
                      FontSize="20"
                      Padding="5"
                      BorderBrush="Black"
                      Margin="10"
                      BorderThickness="3">

                <Grid Margin="10">

                    <Grid.RowDefinitions>
                        <RowDefinition/>
                        <RowDefinition/>
                        <RowDefinition/>
                        <RowDefinition/>
                    </Grid.RowDefinitions>

                    <!--Элементы в GroupBox-->
                    <StackPanel>

                        <TextBlock Text="Название организации"/>
                        <TextBox Name="customerNameRegTxb"
                                 Background="WhiteSmoke"
                                 Height="35"
                                 VerticalContentAlignment="Center"/>

                    </StackPanel>

                    <StackPanel Grid.Row="1">

                        <TextBlock Text="Логин"/>
                        <TextBox Name="customerLoginRegTxb"
                                 Background="WhiteSmoke"
                                 Height="35"
                                 VerticalContentAlignment="Center"/>

                    </StackPanel>

                    <StackPanel Grid.Row="2">

                        <TextBlock Text="Пароль"/>
                        <PasswordBox Name="customerPassRegPbx"
                                     Height="35"
                                     Background="WhiteSmoke"
                                     VerticalContentAlignment="Center"/>

                    </StackPanel>

                    <StackPanel Grid.Row="3">

                        <TextBlock Text="Email"/>
                        <TextBox Name="customerEmailRegTxb"
                                 Height="35"
                                 Background="WhiteSmoke"
                                 VerticalContentAlignment="Center"/>

                    </StackPanel>

                </Grid>

            </GroupBox>

            <Button Name="regCustomerBtn"
                    Style="{DynamicResource ButtonStyle}"
                    Grid.Row="1"
                    Content="Зарегистрироваться"
                    FontSize="18"
                    Width="300"
                    Click="RegCustomerBtn_Click"/>
        </Grid>
        <!--#endregion ФОРМА ДЛЯ РЕГИСТРАЦИИ ЗАКАЗЧИКА -->

        <!--#region ФОРМА ДЛЯ АВТОРИЗАЦИИ АДМИНА-->
        <Grid Name="gridFormAuthАdmin"
              VerticalAlignment="Center"
              Height="300"
              Width="500"
              Visibility="Hidden">

            <Grid.RowDefinitions>
                <RowDefinition/>
                <RowDefinition Height="50"/>
            </Grid.RowDefinitions>

            <GroupBox Header="Вход за админа"
                      Foreground="Black"
                      FontSize="20"
                      Padding="5"
                      BorderBrush="Black"
                      Margin="10"
                      BorderThickness="3">

                <Grid Margin="10">

                    <Grid.RowDefinitions>
                        <RowDefinition/>
                        <RowDefinition/>
                    </Grid.RowDefinitions>

                    <!--Элементы в GroupBox-->
                    <StackPanel>

                        <TextBlock Text="Логин"/>
                        <TextBox Name="adminLoginAuthTxb"
                                 Background="WhiteSmoke"
                                 Height="35"
                                 VerticalContentAlignment="Center"/>

                    </StackPanel>

                    <StackPanel Grid.Row="1">

                        <TextBlock Text="Пароль"/>
                        <PasswordBox Name="adminPassAuthPbx"
                                     Height="35"
                                     Background="WhiteSmoke"
                                     VerticalContentAlignment="Center"/>

                    </StackPanel>

                </Grid>

            </GroupBox>

            <Button Name="authAdminBtn"
                    Grid.Row="1"
                    Style="{DynamicResource ButtonStyle}"
                    Content="Войти"
                    FontSize="20"
                    Width="200"
                    Click="AuthAdminBtn_Click"/>

        </Grid>

    </Grid>
</Page>
